package com.happy.entity;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

@TableName ("note_info")
public class NoteEntity extends BaseEntity {

    @TableId (value = "id", type = IdType.AUTO)
    private Integer id;
    @TableField ("noteTitle")
    private String noteTitle;
    @TableField ("level")
    private Integer level;
    @TableField ("noteContent")
    private String noteContent;
    @TableField ("categoryId")
    private Integer categoryId;

    @TableField(exist = false)
    private String categoryName;

    @TableField ("createTime")
    private Date createTime;
    @TableField ("changeTime")
    private Date changeTime;
    @TableField ("isUsed")
    private Integer isUsed;

    @TableField(exist = false)
    private String fileUrl;

    public Integer getId () {
        return id;
    }

    public void setId (Integer id) {
        this.id = id;
    }

    public String getNoteTitle () {
        return noteTitle;
    }

    public void setNoteTitle (String noteTitle) {
        this.noteTitle = noteTitle;
    }

    public Integer getLevel () {
        return level;
    }

    public void setLevel (Integer level) {
        this.level = level;
    }

    public String getNoteContent () {
        return noteContent;
    }

    public void setNoteContent (String noteContent) {
        this.noteContent = noteContent;
    }

    public Integer getCategoryId () {
        return categoryId;
    }

    public void setCategoryId (Integer categoryId) {
        this.categoryId = categoryId;
    }

    public Date getCreateTime () {
        return createTime;
    }

    public void setCreateTime (Date createTime) {
        this.createTime = createTime;
    }

    public Date getChangeTime () {
        return changeTime;
    }

    public void setChangeTime (Date changeTime) {
        this.changeTime = changeTime;
    }

    public Integer getIsUsed () {
        return isUsed;
    }

    public void setIsUsed (Integer isUsed) {
        this.isUsed = isUsed;
    }

    public String getCategoryName () {
        return categoryName;
    }

    public void setCategoryName (String categoryName) {
        this.categoryName = categoryName;
    }

    public String getFileUrl () {
        return fileUrl;
    }

    public void setFileUrl (String fileUrl) {
        this.fileUrl = fileUrl;
    }

    @Override
    public String toString () {
        return "NoteEntity{" +
                "id=" + id +
                ", noteTitle='" + noteTitle + '\'' +
                ", level=" + level +
                ", noteContent='" + noteContent + '\'' +
                ", categoryId=" + categoryId +
                ", categoryName='" + categoryName + '\'' +
                ", createTime=" + createTime +
                ", changeTime=" + changeTime +
                ", isUsed=" + isUsed +
                ", fileUrl='" + fileUrl + '\'' +
                '}';
    }
}
